package com.xinshujia.entity;

import com.baomidou.mybatisplus.annotation.*;
import com.google.gson.annotations.JsonAdapter;
import com.xinshujia.configuration.adapter.LocalDateTimeAdapter;

import java.time.LocalDateTime;

/**
 * *************************************
 * *   @author: 野狼上校               **
 * *   @since: 2024-07-19 19:51       **
 * *   @version: 1.0                  **
 * *************************************
 * <p>
 * 阈值实体类
 */
@TableName("blade_threshold")
public class ThresholdEntity {
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;
    private String deviceGuid;
    // 用户名称
    private String username;
    // 停机值（小于这个值就是停机状态）
    private Double stopMax;
    // x轴阈值
    private Double xThreshold;
    // y轴阈值
    private Double yThreshold;
    // z轴阈值
    private Double zThreshold;
    // 百分比
    private Integer percentage;
    // 保底值
    private Double guarantee;
    // 新增时间
    @TableField(fill = FieldFill.INSERT)
    @JsonAdapter(LocalDateTimeAdapter.class)
    private LocalDateTime createTime;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public String getDeviceGuid() {
        return deviceGuid;
    }

    public void setDeviceGuid(String deviceGuid) {
        this.deviceGuid = deviceGuid;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public Double getStopMax() {
        return stopMax;
    }

    public void setStopMax(Double stopMax) {
        this.stopMax = stopMax;
    }

    public Double getxThreshold() {
        return xThreshold;
    }

    public void setxThreshold(Double xThreshold) {
        this.xThreshold = xThreshold;
    }

    public Double getyThreshold() {
        return yThreshold;
    }

    public void setyThreshold(Double yThreshold) {
        this.yThreshold = yThreshold;
    }

    public Double getzThreshold() {
        return zThreshold;
    }

    public void setzThreshold(Double zThreshold) {
        this.zThreshold = zThreshold;
    }

    public Integer getPercentage() {
        return percentage;
    }

    public void setPercentage(Integer percentage) {
        this.percentage = percentage;
    }

    public Double getGuarantee() {
        return guarantee;
    }

    public void setGuarantee(Double guarantee) {
        this.guarantee = guarantee;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }
}
